package com.suixuan.spring.entity.base;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Inheritance;
import javax.persistence.InheritanceType;
import javax.persistence.MappedSuperclass;

/**
 * @Copyright (c) Nanjing Zhou Su co.,Ltd
 * 
 * @Project oa
 * @Title BaseLongEntityBean.java
 * @Package com.suixuan.spring.entity.base
 * @Description 主键实体类
 * @Author suixuan
 * @Editors 1
 * @Date 2010-11-29 上午09:33:45
 * @Note
 * @Version:1.0.0
 * 
 */
@MappedSuperclass
@Inheritance(strategy = InheritanceType.JOINED)
public abstract class BaseLongEntityBean implements Serializable {
	/**
	 * 
	 */
	private static final long serialVersionUID = 4426408138675050216L;
	protected Long id = 0L;

	@Id
	@Column(name = "_id")
	@GeneratedValue(strategy = GenerationType.AUTO)
	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public BaseLongEntityBean(Long id) {
		super();
		this.id = id;
	}

	public BaseLongEntityBean() {
		super();
	}

}
